<!DOCTYPE html>
<html>
	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
	<link rel="stylesheet" href="http://twitter.github.com/bootstrap/1.3.0/bootstrap.min.css">
	  <script>
	  /* when document is ready */
	  $(function() {
		/* initiate plugin */
		$("div.holder").jPages({
		  containerID: "itemContainer"
		});
	  });
	  </script>
	<style type="text/css">
	a.disabled {
		text-decoration: none;
		color: black;
		cursor: default;
	}
	 #example4,
	 #example4-pagination {
		display: none;
	}
	.tbl1 {
		background-image:url(../images/datebox.png) no-repeat 4px 4px; border:1px solid red;
    }
	  .holder {
			margin: 15px 0;
	  }
	  .holder a {
		font-size: 12px;
		cursor: pointer;
		margin: 0 5px;
		color: #333;
	  }
	  .holder a:hover {
		background-color: #222;
		color: #fff;
	  }
	  .holder a.jp-previous { margin-right: 15px; }
	  .holder a.jp-next { margin-left: 15px; }
	  .holder a.jp-current, a.jp-current:hover {
		color: #FF4242;
		font-weight: bold;
	  }
	  .holder a.jp-disabled, a.jp-disabled:hover {
		color: #bbb;
	  }
	  .holder a.jp-current, a.jp-current:hover,
	  .holder a.jp-disabled, a.jp-disabled:hover {
		cursor: default;
		background: none;
	  }
	  .holder span { margin: 0 5px; }
	  table{
		border-collapse:collapse;
		width:100%;
	  }
	  table, td, th
	  {
	   border:1px solid black;
	  }
	    
	</style>
<body>

<!--CONTENT SECTION START-->

<div id="main-wrapper-sec">

<section>

	<!--INNER MAIN TITLE SECTION START-->

    <h2 class="inner-main-title pr-title">paymentHistory</h2>
    
    <!--INNER MAIN TITLE SECTION END-->
    
    <!--CONTENT MAIN SECTION START-->
    
  <div class="content-main-sec">
  
  <!--INNER CONTENT LEFT MENU SECTION START-->
  
  <ul class="inner-left-menu-sec">
    <?php include('leftmenu.phtml');?>
  </ul>
  
  <!--INNER CONTENT LEFT MENU SECTION END-->
  
  <!--INNER CONTENT RIGHT SECTION START-->
  
  <article class="inner-cont-right-sec">
  
	<h1 class="inner-cont-title">Payment History</h1>
		<ul class="acc-sd-sec">
		  <li>
			<li><a href="<?php echo $this->url('payments', array('action' => 'payments')); ?>" class="pa-st-sec" ><img src="<?php echo $this->basePath(); ?>/images/packages-icon.png" alt="">Payments</a> <a href="<?php echo $this->url('payment-history', array('action' => 'payment-history')); ?>" class="pa-st-sec" ><img src="<?php echo $this->basePath(); ?>/images/package-history-icon.png" alt="">Payment History</a></li>
		  </li>
		</ul>
	<div class="clear"></div>
	<div class="cd-sf-sec" style="width:765px;">
		<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
			<tr class="title">
				<td width="20%" align="left" valign="middle">Fee</td>
				<td width="20%" align="left" valign="middle">Type</td>
				<td width="20%" align="left" valign="middle">PayType</td>
				<td width="20%" align="left" valign="middle">Money</td>
				<td width="20%" align="left" valign="middle">PayTime</td>
			</tr>
			<?php if($payment==''){ ?>
			<tr><td style="text-align:center;"colspan="5">No History.....</td></tr>
			<?php } ?> 
		</table>
		
		<ul id="itemContainer" style="margin:0px !important;padding:0px !important">
		<?php $str=0; if($payment!=''){ for($i=0;$i<count($payment['infoPayHistorys']);$i++){ 
				$a='9223372036854775807';
					if($a==$payment['infoPayHistorys'][$i]['payTime']){
						$str='No Expire Time';
					}else{
						$original_timestamp1=$payment['infoPayHistorys'][$i]['payTime'];
						$timestamp1 = (int)substr($original_timestamp1,0,-3);
						$str=date('Y-M-d',$timestamp1);
					} 
		?>
		<table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width='20%'><?php if(isset($payment['infoPayHistorys'][$i]['fee'])){ echo $payment['infoPayHistorys'][$i]['fee'];} ?></td><td width='20%'><?php if(isset($payment['infoPayHistorys'][$i]['type'])){ echo $payment['infoPayHistorys'][$i]['type'];} ?></td><td width='20%'><?php if(isset($payment['infoPayHistorys'][$i]['payType'])){ echo $payment['infoPayHistorys'][$i]['payType'];} ?></td><td width='20%'><?php if(isset($payment['infoPayHistorys'][$i]['customerMoney'])){ echo $payment['infoPayHistorys'][$i]['customerMoney'];} ?></td><td width='20%'><?php if(isset($str)){ echo $str;} ?></td></tr></table>
		<?php } } ?>
		</ul>
		<?php if(isset($payment)){ if($payment!=''){ ?>
		<div class="holder"></div>
		<?php } } ?>
	</div>  
	<div class="clear"></div>
  
  </article>
  
  <!--INNER CONTENT RIGHT SECTION END-->
  
  </div>
  
  <!--CONTENT MAIN SECTION END-->
  
  <div class="clear"></div>
  
  <!--CLIENTS AREA SECTION START-->
  
  <aside class="content-main-sec ot-lg-sec"> <img src="<?php echo $this->basePath(); ?>/images/truste.jpg" alt=""> <img src="<?php echo $this->basePath(); ?>/images/secured.jpg" alt=""> <img src="<?php echo $this->basePath(); ?>/images/mcafeev.jpg" alt="">
    <h3 class="otg-title">Trusted. Safe. Reliable.</h3>
  </aside>
  
  <!--CLIENTS AREA SECTION END-->
  
  <div class="clear"></div>
</section>

</div>

<!--CONTENT SECTION END--> 

</body>
</html>
